/*
Disclaimer of Warranty: THE PACKAGE IS PROVIDED
BY THE COPYRIGHT HOLDER AND CONTRIBUTORS "AS IS'
AND WITHOUT ANY EXPRESS OR IMPLIED WARRANTIES.
THE IMPLIED WARRANTIES OF MERCHANTABILITY,
FITNESS FOR A PARTICULAR PURPOSE, OR NON-INFRINGEMENT
ARE DISCLAIMED TO THE EXTENT PERMITTED BY YOUR LOCAL LAW.
UNLESS REQUIRED BY LAW, NO COPYRIGHT HOLDER OR
CONTRIBUTOR WILL BE LIABLE FOR ANY DIRECT, INDIRECT, INCIDENTAL,
OR CONSEQUENTIAL DAMAGES ARISING IN ANY WAY OUT OF THE USE OF
THE PACKAGE, EVEN IF ADVISED OF THE POSSIBILITY OF SUCH DAMAGE.


(c) Copyright 2013 Edward Principe
All Rights Reserved

*/
#ifndef REGISTER_H
#define REGISTER_H

#include "typemacros.h"

/////////////////////////////////////////////////////////////
// Reg: Structure of a register
/////////////////////////////////////////////////////////////
struct RegByte
{
	VAR_BYTE al;
	VAR_BYTE bl;
	VAR_BYTE cl;
	VAR_BYTE dl;
};

struct RegHalfWord
{
	VAR_HALF_WORD am;
	VAR_HALF_WORD bm;
};

/////////////////////////////////////////////////////////////
// Register: Union of a register
/////////////////////////////////////////////////////////////
union Register
{
	RegByte reg_byte;
	RegHalfWord reg_half_word;
	VAR_WORD reg_word;
};

/////////////////////////////////////////////////////////////
// VasmLine: Structure of a VASM line
/////////////////////////////////////////////////////////////
struct VasmLine
{
	VAR_TOKEN token; // A mnonic
	Register lhs; // The left hand site
	Register rhs; // Right hand side
};

////////////////////////////////////////////////////////////
// Flags
////////////////////////////////////////////////////////////
extern VAR_BOOL g_is_equal; // True if equal
extern VAR_BOOL g_is_greator; // True if greator
extern VAR_BOOL g_is_lessor; // True if lessor

#endif
